<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <div id="test"></div>

    <!-- 引入核心库 -->
    <script type="text/javascript" src="./React-js/16.8/react.development.js"></script>
    <!-- 用于支持react操作DOM -->
    <script text="text/javascript" src="./React-js/16.8/react-dom.development.js"></script>
    <!-- 用于将jsx转换为js -->
    <script text="text/javascript" src="./React-js/16.8/babel.min.js"></script>

    <!-- 一定是babel -->
    <script type="text/babel">
        // 创建虚拟dom
        const VDOM = <h1>Hello.React</h1>
        const VDOM2 = <h1>----------------</h1>
        // 渲染虚拟DOM到页面（后面的会替换之前）
        ReactDOM.render(VDOM,document.getElementById('test'))
        ReactDOM.render(VDOM2,document.getElementById('test'))
    </script>
</body>
</html>